from . import flutter

TextStyle = flutter.TextStyle
Container = flutter.Container
Center = flutter.Center
Text = flutter.Text
Stack = flutter.Stack
Positioned = flutter.Positioned
Transform = flutter.Transform
LinearGradient = flutter.LinearGradient
Colors = flutter.Colors
TextAlign = flutter.TextAlign
EdgeInsets = flutter.EdgeInsets
FontWeight = flutter.FontWeight
FontStyle = flutter.FontStyle
BoxShadow = flutter.BoxShadow
BoxShape = flutter.BoxShape
RichText = flutter.RichText
TextSpan = flutter.TextSpan
TextOverflow = flutter.TextOverflow
BorderRadius = flutter.BorderRadius
Offset = flutter.Offset
Scaffold = flutter.Scaffold
AppBar = flutter.AppBar
IconButton = flutter.IconButton
Icon = flutter.Icon
Icons = flutter.Icons

### Banners
MaterialBanner = flutter.MaterialBanner
# CircleAvatar = flutter.CircleAvatar
FlatButton = flutter.FlatButton
###
PopupMenuDivider = flutter.PopupMenuDivider
### Lists
ListView = flutter.ListView
ListTile = flutter.ListTile


def lists():
    return Scaffold(
        appBar=AppBar(
            leading=Icon(Icons.home),
            title=Text('Home'),
        ),
        body=ListView(
            # single-line list
            children=[
                ListTile(
                    title=Text('Banners'),
                    leading=Icon(Icons.school),
                    trailing=Text('Metadata'),
                    href="pages/banners.html",
                    color="blue",
                ),
                PopupMenuDivider(),
                ListTile(
                    title=Text('Buttons'),
                    leading=Icon(Icons.smart_button),
                    trailing=Text('Metadata'),
                    color="red",
                ),
                PopupMenuDivider(),
                ListTile(
                    title=Text('Cards'),
                    leading=Icon(Icons.card_membership),
                    trailing=Text('Metadata'),
                ),
                PopupMenuDivider(),
                ListTile(
                    title=Text('Checkboxes'),
                    leading=Icon(Icons.check),
                    trailing=Text('Metadata'),
                ),
                PopupMenuDivider(),
                ListTile(
                    title=Text('Chips'),
                    leading=Icon(Icons.smart_toy),
                    trailing=Text('Metadata'),
                ),
                PopupMenuDivider(),
                ListTile(
                    title=Text('Data-Tables'),
                    leading=Icon(Icons.table_chart),
                    trailing=Text('Metadata'),
                ),
                PopupMenuDivider(),
                ListTile(
                    title=Text('Dialogs'),
                    leading=Icon(Icons.chat),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Lists'),
                    leading=Icon(Icons.list),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Menus'),
                    leading=Icon(Icons.menu_book),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Navigation-Drawer'),
                    leading=Icon(Icons.draw),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Radio-Buttons'),
                    leading=Icon(Icons.radio_button_checked),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Sliders'),
                    leading=Icon(Icons.slideshow),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Snackbars'),
                    leading=Icon(Icons.bar_chart),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Switches'),
                    leading=Icon(Icons.switch_right),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Tabs'),
                    leading=Icon(Icons.tab),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Text-Fields'),
                    leading=Icon(Icons.text_fields),
                    trailing=Text('Metadata'),
                ),
                ListTile(
                    title=Text('Tooltips'),
                    leading=Icon(Icons.tips_and_updates),
                    trailing=Text('Metadata'),
                ),
            ],
        ),
    )


def run_app():
    test_ = lists()
    javascript.document.body.appendChild(test_.render())

run_app()
